#! /bin/bash
n=74
str1=www.yuque.com$n str2="shell \"script\" $n"
str3='中文网 $n'

echo $str1
echo $str2
echo $str3

email="shenshuai89@qq.com"
echo ${email#*sh}
echo ${email##*sh}
echo ${email%shuai*}

# 定义时间
TIMENOW = `date '+%Y%m%d%H%M%S'`
timenow = $(date '+%Y%m%d%H%M%S')
echo ${TIMENOW}
echo ${timenow}

testsh=$(cat ./test.sh)
# 使用双引号包围变量，可以使变量内的空白以及换行都能正确显示
echo "${testsh}"

begin_time=$(date +%s)
sleep 2s
finish_time=$(date +%s)
run_time=$((finish_time - begin_time))
echo "begin_time:$begin_time"
echo "finish_time:$finish_time"
echo "run_time:$run_time"

echo "$(ls -l)"
echo $(ls -l)



